Skip to content

Add an opt-in V2 scan builder and execution path - #10302

Open
joseph-isaacs wants to merge 4 commits into
developfrom
ji/scan-v2-builder
Open

joseph-isaacs wants to merge 4 commits into
developfrom
ji/scan-v2-builder

Conversation

@joseph-isaacs

@joseph-isaacs joseph-isaacs commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Introduce a separate V2 scan builder and an opt-in branch in DuckDB and DataFusion so the new scan implementation can land incrementally. With VORTEX_SCAN_V2=1, both engines use vortex_layout::scan::v2::ScanBuilder; otherwise they keep their current path. The flag is read once per process.

This PR targets develop directly and can merge independently of the protocol stack (#10047, #10048, #10049). It establishes the structure for follow-on planner, execution graph, and IO changes. It does not yet execute scans through the new planning protocol.

Changes

  • Copy the current builder, lazy stream, and repeated-scan implementation into scan::v2, retaining the existing split tasks for initial behavior parity.
  • Add ScanBuilder::from_default and a crate-private configuration transfer that moves every builder option, including selection, natural splits, ordering, concurrency, mapping, limits, and row offsets.
  • Select the V2 builder at the DuckDB preparation and DataFusion stream entry points.
  • Include parity tests for filtering, row ranges, limits, and repeated execution, plus checks that conversion preserves selection, mapping, concurrency, ordering, and supplied split boundaries.

Validation: the initial CI run passed Rust builds and tests, SQL logic tests, and Clippy; the formatting differences in the new tests are fixed with nightly-2026-09-10. DCO now passes. The first S3 run failed during RustFS bucket setup; service startup passed on retry. A later run exposed the same stale OpenDAL dependency edges in develop's lockfile, so this branch includes current develop and Cargo's three-entry lockfile repair. cargo metadata --locked --format-version 1, scoped formatting, and git diff --check pass locally. CI is rerunning on the updated branch.

Copy the current scan builder and repeated scan into scan::v2, and select
that path in DuckDB and DataFusion with VORTEX_SCAN_V2=1. Transfer every
configured builder option when switching paths. Keep the existing split
tasks so the new planning protocol and executor can land incrementally.

Include scan parity and configuration-transfer tests.

Signed-off-by: "Joe Isaacs" <joe.isaacs@live.co.uk>
@joseph-isaacs joseph-isaacs added the changelog/chore A trivial change label Oct 5, 2026
Apply nightly-2026-09-10 formatting to the new scan tests.

DCO Remediation Commit for Joe Isaacs <joe.isaacs@live.co.uk>

I, Joe Isaacs <joe.isaacs@live.co.uk>, hereby add my Signed-off-by to this commit: ddd623d

Signed-off-by: "Joe Isaacs" <joe.isaacs@live.co.uk>
Signed-off-by: Joe Isaacs <joe.isaacs@live.co.uk>
Current develop's Cargo.lock links three OpenDAL packages to asyncband
0.7.2, but Cargo resolves them to the already-locked 0.7.3. Regenerate
those dependency edges with Cargo so --locked CI commands can run.

Signed-off-by: "Joe Isaacs" <joe.isaacs@live.co.uk>
Signed-off-by: Joe Isaacs <joe.isaacs@live.co.uk>
@codspeed

codspeed Bot commented Oct 5, 2026 •

Copy link
Copy Markdown

Merging this PR will not alter performance

⚠️ Unknown Walltime execution environment detected

Using the Walltime instrument on standard Hosted Runners will lead to inconsistent data.

For the most accurate results, we recommend using CodSpeed Macro Runners: bare-metal machines fine-tuned for performance measurement consistency.

✅ 2095 untouched benchmarks
⏩ 518 skipped benchmarks1


Comparing ji/scan-v2-builder (c3cdbb5) with develop (76381d5)

Open in CodSpeed

Footnotes

  1. 518 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩

Remove ScanParts and into_parts once the V2 migration is complete.

Signed-off-by: "Joe Isaacs" <joe.isaacs@live.co.uk>
Signed-off-by: Joe Isaacs <joe.isaacs@live.co.uk>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog/chore A trivial change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant